package spring.aop;

import org.springframework.context.ApplicationContext;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class Main {
	public static void main(String[] args) {
		ApplicationContext ctx=new ClassPathXmlApplicationContext("applicationContext.xml");
		ArithmeticCalculator arithmeticCalculator=(ArithmeticCalculator) ctx.getBean("arithmeticCalculatorImpl");
		
		int result=arithmeticCalculator.add(1, 1);
		System.out.println("result "+ result);
		result=arithmeticCalculator.div(2,2);
		System.out.println("result "+result);
	}
}
